/******************************************************************************
 * (c) 2011 Komersi Software                                                  *
 * www.komersisoftware.com                                                    *
 *                                                                            *
 * This file is part of Tadah                                                 *
 * Licensed under GNU General Public License v2.0                             *
 * Check LICENSE.TXT for more information                                     *
 ******************************************************************************/

#include <stdio.h>
#include <time.h>

#include "debug.h"

#ifdef __linux__

inline void debug(const char *message)
{
	fprintf(stdout, "%s\n", message);
}

#else
 
#ifndef _MSC_VER
inline
#endif
void debug(const char *message)
{ 
  char date[9], time[9];
  
  _strdate(date);
  _strtime(time);
  
  fprintf(stdout, "%s %s - %s\n", date, time, message);
}
#endif

#ifndef _MSC_VER
inline
#endif
void debug_print_ddl_column(ddl_column_t *column)
{
   debug("Printing contents of ddl_column_t");
   fprintf(stdout, "NAME: %s\n", column-> name);
   fprintf(stdout, "DATATYPE: %d\n", column->type);
   fprintf(stdout, "SIZE: %d\n", column->size);
}
